package com.jjw.route.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurationSupport;

@Configuration
public class MyInterceptorConfig extends WebMvcConfigurationSupport {

    @Override
    protected void addInterceptors(InterceptorRegistry registry) {
        registry.addInterceptor(new LoginUserInterceptor()).addPathPatterns("/abc/");
//                .addPathPatterns("/**")
//                .excludePathPatterns("/route/user/login")
//                .excludePathPatterns("/route/user/register")
//                .excludePathPatterns("/route/poi/topPoi")
//                .excludePathPatterns("/route/artical/list")
//                .excludePathPatterns("/route/poi/rankList")
//                .excludePathPatterns("/route/poi/allPoi")
//                .excludePathPatterns("/route/artical/imgUp");
        super.addInterceptors(registry);
    }
}
